import 'package:flutter_nb_net/flutter_net.dart';

class SoundListResp extends BaseNetModel {
  int? code;
  String? msg;
  List<SoundData>? rows;

  SoundListResp({this.code, this.msg, this.rows});

  @override
  fromJson(Map<String, dynamic> json) {
    return SoundListResp(
      code: json['code'],
      msg: json['msg'],
      rows: json['rows'] != null ? List<SoundData>.from(json['rows'].map((x) => SoundData().fromJson(x))) : null,
    );
  }
}

class SoundData extends BaseNetModel {
  bool? read;
  String? id;
  String? messageType;
  String? time;
  String? createTime;
  String? url;
  String? title;

  bool isPlay = false;

  SoundData({this.read, this.id, this.messageType, this.time, this.createTime, this.url, this.title});

  @override
  fromJson(Map<String, dynamic> json) {
    return SoundData(
      read: json['read'],
      id: json['id'],
      messageType: json['messageType'],
      time: json['time'],
      createTime: json['createTime'],
      url: json['url'],
      title: json['title'],
    );
  }

}